home *** CD-ROM | disk | FTP | other *** search
- -- stack: in.3
- -- format: 8 (HyperCard 1)
- -- flags: 0x0 (none)
- -- protect password hash: 0
- -- maximum user level: 5 (scripting)
- -- window: Rect(x1=0, y1=0, x2=0, y2=0)
- -- screen: Rect(x1=0, y1=0, x2=0, y2=0)
- -- card dimensions: w=0 h=0
- -- scroll: x=0 y=0
- -- background count: 4
- -- first background id: 2737
- -- card count: 12
- -- first card id: 3853
- -- list block id: 4555
- -- print block id: 4650
- -- font table block id: 0
- -- style table block id: 0
- -- free block count: 0
- -- free size: 0 bytes
- -- total size: 46752 bytes
- -- stack block size: 8192 bytes
- -- created by hypercard version: 0x00000000
- -- compacted by hypercard version: 0x00000000
- -- modified by hypercard version: 0x00000000
- -- opened by hypercard version: 0x00000000
- -- patterns[0]: 0x0000000000000000
- -- patterns[1]: 0x8000000008000000
- -- patterns[2]: 0x8800220088002200
- -- patterns[3]: 0x8888222288882222
- -- patterns[4]: 0x88AA22AA88AA22AA
- -- patterns[5]: 0xCCAA33AACCAA33AA
- -- patterns[6]: 0xEEAABBAAEEAABBAA
- -- patterns[7]: 0xEEBBBBEEEEBBBBEE
- -- patterns[8]: 0xFFBBFFEEFFBBFFEE
- -- patterns[9]: 0xFFBBFFFFFFBBFFFF
- -- patterns[10]: 0x8010022001084004
- -- patterns[11]: 0xFFFFFFFFFFFFFFFF
- -- patterns[12]: 0x8822882288228822
- -- patterns[13]: 0x1122448811224488
- -- patterns[14]: 0xC4800C6843023026
- -- patterns[15]: 0xB130031BD8C00C8D
- -- patterns[16]: 0xAA00AA00AA00AA00
- -- patterns[17]: 0x8822552288225522
- -- patterns[18]: 0x8855225588552255
- -- patterns[19]: 0x77DD77DD77DD77DD
- -- patterns[20]: 0x8000000000000000
- -- patterns[21]: 0xAA55AA55AA55AA55
- -- patterns[22]: 0x038448300C020101
- -- patterns[23]: 0x8244394482010101
- -- patterns[24]: 0x8814224188412214
- -- patterns[25]: 0x8080413E080814E3
- -- patterns[26]: 0x22048C7422179810
- -- patterns[27]: 0xBE808808EB088880
- -- patterns[28]: 0x25C8328964244C92
- -- patterns[29]: 0xA29C41BE2AC914EB
- -- patterns[30]: 0x40A00000040A0000
- -- patterns[31]: 0x8040200002040800
- -- patterns[32]: 0xAA00800088008000
- -- patterns[33]: 0xFF80808080808080
- -- patterns[34]: 0x081C22C180010204
- -- patterns[35]: 0xFF808080FF080808
- -- patterns[36]: 0xF87422478F172271
- -- patterns[37]: 0xBF00BFBFB0B0B0B0
- -- patterns[38]: 0xFF7FBE5DA2418000
- -- patterns[39]: 0xFAF5FAF5A050A050
- -- checksum: 0x0
- ----- HyperTalk script -----
- on openstack
- set userlevel to 5
- hide menubar
- get short name of stack
- put it into card field "stkname"
- wait 2 seconds
- go to card "ChptLstCrd"
- end openstack
-
- on domenu
- global ptype
- put the param of 1 into ptype
- if ptype contains "paste" then
- if ptype is "paste card" then
- get the short name of the target
- if it is "Add topics" or it is "Contents" or it is "Insert" then
- pass domenu
- else -- pasting but not card
- beep 1
- put "Make menus first, THEN copy text/graphics, not vice versa!"
- answer "You are trying to paste a card!..." with "OK"
- answer "Only Summarizer may paste cards!" with "OK"
- put empty into msg
- hide msg
- exit domenu
- end if
- end if
- answer "About to" && ptype && "from clipboard" with "Cancel" or "OK"
- if it is "Cancel" then exit domenu
- end if
- if ptype contains "cut" or ptype contains "copy" then
- if ptype is "cut picture" or ptype is "copy picture" then
- put "Make menus first, THEN copy text/graphics, not vice versa!"
- answer "Have you made menus for this graphic yet?" with "No" or "Yes"
- if it is "No" then
- hide msg
- exit domenu
- end if
- end if
- if ptype is "cut " then
- beep 1
- answer "There must be graphics to cut!" with "OK"
- exit domenu
- end if
- end if
- hide msg
- pass domenu
- end domenu
-
- on MakePage
- put empty into NwCrd
- put field "HeaderFld" into StrtCrdHeader
- put short name of next card into RCard
- put short name of this card into StrtCrd
- set lockscreen to "true"
- if RCard is "@" then
- domenu "new card"
- set name of this card to "@"
- if StrtCrd is "@" then
- put StrtCrdHeader into field "HeaderFld"
- else
- put "…" && StrtCrdHeader && "Cont." into field "HeaderFld"
- end if
- put "true" into NwCrd
- else
- put "false" into NwCrd
- end if
- domenu "new button"
- set name of button "new button" to "NxtPg"
- set showname of button "NxtPg" to false
- set rect of button "NxtPg" to 460, 0, 480, 17
- set icon of button "NxtPg" to "sml Next Arrow"
- set loc of button "NxtPg" to 460,8
- set style of button "NxtPg" to opaque
- set script of button "NxtPg" to "On mouseup" & return & "go to next card" & return & "if the number of card fields is 1 then" & return & "get rect of card field" && quote & "txtfld" & quote & return & "delete item 4 of it" & return & "delete item 3 of it" & return & "click at it" & return & "end if" & return & "end mouseup"
- if not NwCrd then
- domenu "new card"
- set name of this card to "@"
- if StrtCrd is "@" then
- put StrtCrdHeader into field "HeaderFld"
- else
- put "…" && StrtCrdHeader && "Cont." into field "HeaderFld"
- end if
- end if
- domenu "new button"
- set name of button "new button" to "PrvPg"
- set showname of button "PrvPg" to false
- set rect of button "PrvPg" to 481, 0, 501, 17
- set icon of button "PrvPg" to "sml Prev Arrow"
- set loc of button "PrvPg" to 481,8
- set style of button "PrvPg" to opaque
- set script of button "PrvPg" to "On mouseup" & return & "go to prev card" & return & "if the number of card fields is 1 then" & return & "get rect of card field" && quote & "txtfld" & quote & return & "delete item 4 of it" & return & "delete item 3 of it" & return & "click at it" & return & "end if" & return &"end mouseup"
- choose browse tool
- end MakePage
-
- on MakeField
- global WindType
- domenu "New field"
- set name of card field "" to "TxtFld"
- set rect of card field "TxtFld" to 19,18,512,342
- if WindType is "Scroll"
- then set Style of card field "TxtFld" to Scrolling
- if WindType is "Reg Text"
- then set Style of card field "Txtfld" to transparent
- set textFont of card field "TxtFld" to geneva
- set TextSize of card field "Txtfld" to 9
- set locktext of card field "Txtfld" to false
- set wideMargins of card field "Txtfld" to true
- put IBeam("TxtFld") into dummy
- end MakeField
-
- on SendTxtToFld
- global Xit, fileName
- put False into Xit
- answer "Stop entry of text..." with "at TAB" or "at RETURN" or "after ? chars"
- put it into Delimiter
-
- if delimiter is "after ? chars" then
- beep 1
- put "30,000 chars max for scroll/reg field! Try 400 for Reg."
- show msg
- ask "Enter number of characters to read"
- if it is empty then
- hide msg
- put true into Xit
- exit SendTxtToFld
- end if
- put it into NumWds
- hide msg
- read from file fileName for NumWds
- end if
-
- if delimiter is "at TAB"
- then read from file fileName until Tab
- if delimiter is "at RETURN"
- then read from file fileName until Return
-
- if it is empty then
- beep 1
- put "End of file!"
- show msg
- wait 2 seconds
- hide msg
- put true into Xit
- exit SendTxtToFld
- end if
-
- put it after card field "TxtFld"
- end SendTxtToFld
-
-
- function Bs10To26 Base10
- put 9999 into quotient
- put empty into Base26
- repeat while quotient is not 0
- put Base10 div 26 into quotient
- put NumToChar of (Base10 mod 26 + 65) before Base26
- put quotient into Base10
- end repeat
- return Base26
- end Bs10To26
-
- function PasteAtPrev template
- go to card template
- domenu "copy card"
- go to prev card
- domenu "paste card"
- end PasteAtPrev
-
- function IBeam CrdFld
- choose browse tool
- set lockscreen to false
- get rect of card field CrdFld
- delete item 4 of it
- delete item 3 of it
- click at it
- end IBeam
-
- function DelCards ChptNam
- go to card ChptNam
- put number of lines in field "TpcLstFld" into LstNum
- domenu "delete card"
- go to card ChptNam & 1
- repeat while short name of this card is not ChptNam & LstNum
- domenu "delete card"
- end repeat
- domenu "delete card"
- repeat while short name of this card is "@"
- domenu "delete card"
- end repeat
- go to card "ChptLstCrd"
- end DelCards
-
-